//
//  NotificationPushHelper.h
//  koolearnMotion
//
//  Created by 崔宝印 on 2017/5/22.
//  Copyright © 2017年 koolearn. All rights reserved.
//


#import <Foundation/Foundation.h>

extern NSString * const kLocalNotificationProductId;
extern NSString * const kLocalNotificationUnitId;
extern NSString * const kLocalNotificationTag;

@interface KooAPNSManager : NSObject
/**
 初始化推送
 */
+ (void)initAliPushWith:(UIApplication *)application options:(NSDictionary *)launchOptions;

/**
 绑定用户/解绑用户
 @param userId 用户ID，为nil时为解绑用户
 */
+ (void)refreshLoginUserId:(NSString *)userId;

/**
 检查是否需要跳转
 原因：当UIWindow的rootcontroller不是UItabviewController时，存储跳转，等UItabviewController加载完时跳转
 */
+ (void)checkNeedJumpApns;

/**
 添加本地直播通知
 @param startTime 开始时间
 @param teacherName 老师名字
 @param productName 直播名称
 @param liveId 直播ID
 */
+ (void)addLoacalNotificationWithStartTime:(NSString *)startTime
                          teacherName:(NSString *)teacherName
                                  liveName:(NSString *)productName
                                    liveId:(NSString *)liveId;

#pragma mark - AppDelegate中添加回调
/**
 APNS注册成功
 @param application UIApplication
 @param deviceToken deviceToken
 */
+ (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)deviceToken;
/**
 APNS注册失败
 @param application UIApplication
 */
+ (void)application:(UIApplication *)application didFailToRegisterForRemoteNotificationsWithError:(NSError *)error;
/**
 iOS10- 收到推送
 @param application UIApplication
 @param userInfo 推送内容
 */
+ (void)application:(UIApplication *)application didReceiveRemoteNotification:(NSDictionary *)userInfo;
@end
